<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<% 

String basePath = request.getScheme() + "://" + request.getServerName()
		+ ":" + request.getServerPort() + request.getContextPath()
		+ "/";

request.setAttribute("basePath", basePath);
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<link rel="stylesheet" href="${basePath}plugin/layer-v2.4/skin/layer.css" type="text/css" media="screen">
<link rel="stylesheet" href="${basePath}plugin/layer-v2.4/css/dialog-common.css" type="text/css" media="screen">
<script type="text/javascript" src="${basePath}plugin/jquery1.10.2/jquery.min.js"></script>
<script type="text/javascript" src="${basePath}plugin/layer-v2.4/layer-debug.js"></script>
<script type="text/javascript">
$(function(){
	$('#btn1').on("click", function(){
		/* var aindex = layer.alert('见到你真的很高兴', {icon: 6});
		layer.title('标题变了', aindex); */
		
		/* 
		layer.open({
			title : "提示",
			content : "layer提示信息",
			icon: 6,
			shadeClose: true,
			btn : ['按钮一', '按钮二', '按钮三'],
			yes: function(index, layero){
			    alert("按钮【按钮一】的回调");
			  },btn2: function(index, layero){
			    alert("按钮【按钮二】的回调");
			  },btn3: function(index, layero){
			    alert("按钮【按钮三】的回调");
			  }
			  ,cancel: function(){ 
			    alert("右上角关闭回调");
			  }
		}); */
/* 		
	 	$.post("http://localhost:8080/images/", {}, function(str){
			 var cwindows = layer.open({
			    type: 1,
			    title: ["提示", "cursor: pointer;"],
				area: ['400px', '300px'],
				move: false,
			    content: str //注意，如果str是object，那么需要字符拼接。
			  });
			 
			 	$("#closewindows").on("click", function(){
			 		layer.close(cwindows);
			 	});
			});  */
		
		/* layer.open({
			title: ['标题', 'dialog-title'],
			  type: 2, 
			  area: ['600px', '360px'],
		      shadeClose: true,
			  content: ['http://localhost:8080/images/fileListPreview', 'no']
			}); */
			/* layer.open({
				type : 1,
				title: ["提示222", "cursor: pointer;"],
				area: ['400px', '300px'],
				move: false,
			    shadeClose: true,
				content: '<div><div class="word-tip">文件详细列表</div><a href="http://localhost:8080/images/fileListPreview" class="linked-btn">查看</a></div>'
			}); */
//			alert(1);
//		layer.alert('加了个图标0', {icon: 0, title:false, closeBtn: 0});
//		layer.alert('加了个图标1', {icon: 1, title:false, closeBtn: 0});
//		layer.alert('加了个图标2', {icon: 2, title:false, closeBtn: 0});
//		layer.alert('加了个图标3', {icon: 3, title:false, closeBtn: 0});
//		layer.alert('加了个图标4', {icon: 4, title:false, closeBtn: 0});
//		layer.alert('加了个图标5', {icon: 5, title:false, closeBtn: 0});
//		layer.alert('加了个图标6', {icon: 6, title:false, closeBtn: 0});
		//自定义弹窗样式
		 var cwindows = layer.open({
			    type: 1,
			    title: ["提示信息", "cursor: pointer;"],
				area: ['400px', '245px'],
				move: false,
			    content:"2222" //注意，如果str是object，那么需要字符拼接。
			  });
		
	});
});
</script>
</head>
<body>
	<button id="btn1">弹窗</button>
</body>
</html>